#define _CRT_SECURE_NO_WARNINGS 1
#include<iostream>
#include<algorithm>
using namespace std;
const int N = 16010;
int a[N];
int main()
{
	int s1, s2, s3;
	cin >> s1 >> s2 >> s3;
	for (int i = 1; i <= s1; i++)
	{
		for (int j = 1; j <= s2; j++)
		{
			for (int k = 1; k <= s3; k++)
			{
				a[i + j + k]++;
			}
		}
	}
	int maxx = 0,t;
	for (int i = 3; i <= 80; i++)
	{
		if (a[i] > maxx)
		{
			maxx = max(maxx, a[i]);
			t = i;
		}
	}
	cout << t << endl;
	return 0;
}